package com.zbkj.front.controller.user.bindcity;

import com.zbkj.common.model.community.CommunityCategory;
import com.zbkj.common.request.bindcity.UserBindCityRequest;
import com.zbkj.common.result.CommonResult;
import com.zbkj.service.service.UserService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;


/**
 * @ClassName: UserBindCityController
 * @Description: TODO
 * @Author: fanbing
 * @Date: 2024/8/10 11:35
 * @Version: V1.0
 **/
@Slf4j
@RestController
@RequestMapping("api/front/userBindCity")
@Api(tags = "用户绑定城市")
public class UserBindCityController {


    @Autowired
    private UserService userService;

    @ApiOperation(value = "绑定城市")
    @RequestMapping(value = "/bindCity", method = RequestMethod.POST)
    public CommonResult bindCity(@RequestBody UserBindCityRequest request) {
        return CommonResult.success(userService.bindCity(request));
    }
}
